package com.baidu.shop.response;

import com.baidu.shop.base.Result;
import com.baidu.shop.document.GoodsDoc;
import com.baidu.shop.entity.BrandEntity;
import com.baidu.shop.entity.CategoryEntity;
import com.baidu.shop.status.HTTPStatus;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;
import java.util.Map;

/**
 * @Description:
 * @ClassName: GoodsResponse
 * @Author: User
 * @date: 2020.09.21 14:23
 * @version: 1.0
 */
@Data
@NoArgsConstructor
public class GoodsResponse extends Result<List<GoodsDoc>> {
    private Integer total;

    private Integer totalPage;

    private List<BrandEntity> brandList;

    private List<CategoryEntity> categoryList;

    private Map<String, List<String>> specMap;

    public GoodsResponse(Integer total, Integer totalPage, List<BrandEntity> brandList,
                         List<CategoryEntity> categoryList, List<GoodsDoc> goodsDocs,
                         Map<String, List<String>> specMap){

        super(HTTPStatus.OK,HTTPStatus.OK + "",goodsDocs);
        this.total = total;
        this.totalPage = totalPage;
        this.brandList = brandList;
        this.categoryList = categoryList;
        this.specMap=specMap;
    }
}
